home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tricks of the Mac Game Programming Gurus
/
TricksOfTheMacGameProgrammingGurus.iso
/
More Source
/
Libraries
/
SAT 2.3b4
/
Misc
/
TransSkel
/
PPCTransSkelCallProcs.c
next >
Wrap
Text File
|
1994-12-06
|
2KB
|
42 lines
// C library to replace the inlines of TransSkel. This is a temporary solution
// until they fix the - much needed - ability to call procedure pointers.
typedef pascal void (*CallpMousePtr)(Point thePoint,long theTime, short theMods);
pascal void CallpMouse (Point thePoint,long theTime, short theMods, CallpMousePtr myProc){
(*myProc)(thePoint, theTime, theMods);
}
typedef pascal void (*CallpKeyPtr)(char theChar, short theMods);
pascal void CallpKey (char theChar, short theMods, CallpKeyPtr myProc){
(*myProc)(theChar, theMods);
}
typedef pascal void (*CallpEventPtr)(short theitem, EventRecord *theEvent);
pascal void CallpEvent (short theitem, EventRecord *theEvent, CallpEventPtr myProc){
(*myProc)(theitem, theEvent);
}
typedef pascal Boolean (*CallotherEventPtr)(EventRecord *theEvent);
pascal Boolean CallotherEvent (EventRecord *theEvent, CallotherEventPtr myProc){
return (*myProc)(theEvent);
}
typedef pascal void (*CallpBooleanPtr)(Boolean myBool);
pascal void CallpBoolean (Boolean myBool, CallpBooleanPtr myProc){
(*myProc)(myBool);
}
typedef pascal void (*CallpIntPtr)(short myInt);
pascal void CallpInt (short myInt, CallpIntPtr myProc){
(*myProc)(myInt);
}
typedef pascal void (*CallpMenuPtr)(MenuHandle myMenu);
pascal void CallpMenu (MenuHandle myMenu, CallpMenuPtr myProc){
(*myProc)(myMenu);
}
typedef pascal void (*CallpnoargPtr)();
pascal void Callpnoarg (CallpnoargPtr myProc){
(*myProc)();
}
typedef pascal void (*CallpfilterPtr)(DialogPtr theDialog, EventRecord *theEvent, Boolean *result);
pascal void Callpfilter (DialogPtr theDialog, EventRecord *theEvent, Boolean *result, CallpfilterPtr myProc){
(*myProc)(theDialog, theEvent, result);
}